﻿package Message.Public
{
    import Framework.MQ.*;
    import Framework.Serialize.*;
    import flash.utils.*;

    public class SDefenseCopyReward extends IMessageBase
    {
        public var coin:int;
        public var bindCoin:int;
        public var bindGold:int;
        public var experience:int;
        public var equipPoint:int;
        public var rewards:Dictionary;
        public const _type:int = 5015;
        public static var _regist:SDefenseCopyReward = new SDefenseCopyReward(true);

        public function SDefenseCopyReward(param1:Boolean = false)
        {
            if (param1)
            {
                MessageManager.instance().regist(this);
            }
            return;
        }// end function

        override public function getType() : int
        {
            return this._type;
        }// end function

        override public function clone() : IMessageBase
        {
            return new SDefenseCopyReward();
        }// end function

        override public function __write(param1:SerializeStream) : void
        {
            param1.writeInt(this.coin);
            param1.writeInt(this.bindCoin);
            param1.writeInt(this.bindGold);
            param1.writeInt(this.experience);
            param1.writeInt(this.equipPoint);
            DictIntIntHelper.write(param1, this.rewards);
            return;
        }// end function

        override public function __read(param1:SerializeStream) : void
        {
            this.coin = param1.readInt();
            this.bindCoin = param1.readInt();
            this.bindGold = param1.readInt();
            this.experience = param1.readInt();
            this.equipPoint = param1.readInt();
            this.rewards = DictIntIntHelper.read(param1);
            return;
        }// end function

    }
}
